Skip to content

Conversation

@afc163
Copy link
Member

@afc163 afc163 commented Nov 25, 2025

Updated configuration to use 'umijs' framework.

Summary by CodeRabbit

发布说明

  • 基础设施优化
    • 更新了部署配置以支持最新的部署平台版本。

✏️ Tip: You can customize this high-level summary in your review settings.

Updated configuration to use 'umijs' framework.
@vercel
Copy link

vercel bot commented Nov 25, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
select Ready Ready Preview Comment Nov 25, 2025 3:44am

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 25, 2025

Warning

Rate limit exceeded

@afc163 has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 2 minutes and 33 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 7b85e78 and dfbe101.

📒 Files selected for processing (1)
  • .dumirc.ts (1 hunks)

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Walkthrough

将项目的Vercel部署配置从Now V2格式(now.json)迁移到现代Vercel格式(vercel.json),新配置文件指定构建框架为UmiJS。

Changes

队列 / 文件 变更摘要
部署配置更新
now.jsonvercel.json
删除了Now V2版本的部署配置文件(now.json),添加新的Vercel配置文件(vercel.json)并指定框架为UmiJS

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

  • 配置文件变更,无业务逻辑或代码更改
  • 仅涉及部署工具版本升级

Poem

旧日配置已归档,
兔子跳向新平台,🐰
Vercel新章已启航,
UmiJS相伴左右,
构建流程焕新生!✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title accurately describes the main change: removing now.json and adding vercel.json configuration files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist
Copy link

Summary of Changes

Hello @afc163, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request updates the project's Vercel deployment configuration by transitioning from the legacy now.json file to the modern vercel.json format. This change ensures compatibility with current Vercel practices and explicitly integrates the umijs framework for optimized builds and deployments.

Highlights

  • Configuration File Migration: The project's deployment configuration has been migrated from the deprecated now.json file to the current vercel.json format.
  • UmiJS Framework Integration: The new vercel.json configuration explicitly specifies umijs as the framework, streamlining the deployment process for UmiJS-based projects on Vercel.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@codecov
Copy link

codecov bot commented Nov 25, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.41%. Comparing base (7578c58) to head (dfbe101).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1173   +/-   ##
=======================================
  Coverage   99.41%   99.41%           
=======================================
  Files          31       31           
  Lines        1195     1195           
  Branches      403      425   +22     
=======================================
  Hits         1188     1188           
  Misses          7        7           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request migrates the Vercel configuration from the legacy now.json to vercel.json, correctly specifying umijs as the framework. My review includes a suggestion to add the project name to the new configuration file to maintain consistency with the previous setup and avoid any unexpected changes to the project's name on Vercel.

Comment on lines +1 to +3
{
"framework": "umijs"
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The previous now.json configuration specified a project name with "name": "rc-select". To ensure consistency and prevent the project name on Vercel from changing unexpectedly, it's recommended to also add the name property to your vercel.json configuration.

Suggested change
{
"framework": "umijs"
}
{
"name": "rc-select",
"framework": "umijs"
}

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7578c58 and 7b85e78.

📒 Files selected for processing (2)
  • now.json (0 hunks)
  • vercel.json (1 hunks)
💤 Files with no reviewable changes (1)
  • now.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Analyze (javascript)

Comment on lines +1 to +3
{
"framework": "umijs"
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

验证UmiJS框架标识符和配置完整性

需要确认"umijs"是否为Vercel支持的有效框架标识符,并验证这个最小化配置是否满足项目的部署需求。建议检查原始now.json中是否包含其他需要迁移的配置(如构建命令、输出目录、环境变量等)。

请运行以下脚本验证框架配置的有效性:

另外,您可以通过查阅最新的Vercel框架支持文档来确认"umijs"是否为有效的框架标识符:


🏁 Script executed:

#!/bin/bash
# 搜索项目中是否存在now.json或其备份,查看原始配置内容
fd -e json -type f | grep -E "(now|vercel)" | head -20

# 检查package.json中的UmiJS相关依赖
cat package.json | grep -A 5 -B 5 "umi"

Length of output: 1011


🌐 Web query:

Vercel supported frameworks list umijs

💡 Result:

Yes — Vercel lists UmiJS as a supported framework and provides a deployment guide. See Vercel's supported frameworks list and the UmiJS deploy guide. [1][2]

Sources:
[1] Vercel — Supported Frameworks (includes UmiJS).
[2] Vercel guide: "How to Deploy an UmiJS App with Vercel" (deployment instructions).


需要进一步搜索now.json文件以验证配置完整性。让我运行修正的脚本:


---

🏁 Script executed:

```shell
#!/bin/bash
# 搜索now.json和vercel.json文件
fd -e json -type file | grep -E "(now|vercel)"

# 如果now.json存在,显示其内容
if [ -f "now.json" ]; then
  echo "=== now.json content ==="
  cat now.json
fi

# 如果vercel.json存在,显示其内容
if [ -f "vercel.json" ]; then
  echo "=== vercel.json content ==="
  cat vercel.json
fi

Length of output: 225


需要验证最小化配置是否充分。让我检查项目的构建配置:


---

🏁 Script executed:

```shell
#!/bin/bash
# 搜索项目中的部署相关配置文件
ls -la | grep -E "(vercel|now|build|\.vercel)"

# 检查是否存在构建或部署相关的环境配置
find . -maxdepth 2 -name ".*" -o -name "*config*" | grep -v node_modules | head -20

# 查看package.json中的build脚本
echo "=== Build scripts ==="
grep -A 2 '"build"' package.json

Length of output: 402


需要最后确认Vercel对UmiJS最小配置的支持情况:


---

🌐 Web query:

```web
Vercel UmiJS minimal configuration framework only

💡 Result:

Summary — minimal Vercel setup to deploy an UmiJS app (static output)

  1. package.json (scripts)
  • Ensure you have a build script that runs Umi:
    {
    "scripts": {
    "build": "npx umi build",
    "dev": "npx umi dev",
    "start": "npx umi dev"
    }
    }
  1. vercel.json (minimal, puts Vercel build and serves Umi's dist)
  • Create vercel.json at project root:
    {
    "buildCommand": "npx umi build",
    "outputDirectory": "dist"
    }

Notes

  • Umi’s production build outputs to dist by default (so outputDirectory = "dist"). [1]
  • Vercel will run the buildCommand and serve the files from outputDirectory. Use vercel.json properties buildCommand/outputDirectory to override project settings. [2][3]
  • If your Umi app needs server-side Node APIs (not just static files), you’ll need a different configuration (Vercel Functions or a server runtime) — the above is for static-only builds.

Sources
[1] Umi build output ("npx umi build" → dist).
[2] Vercel docs — vercel.json: buildCommand / outputDirectory.
[3] Vercel project-configuration docs / changelog (per-deployment overrides).


补充buildCommand和outputDirectory配置

vercel.json配置不完整。虽然"umijs"是Vercel支持的有效框架标识符,但Vercel建议在vercel.json中显式指定buildCommand和outputDirectory来确保正确部署。根据UmiJS的默认构建输出为dist目录,建议修改为:

{
  "buildCommand": "npm run build",
  "outputDirectory": "dist"
}

注意:项目中build脚本为"dumi build"而非"umi build",请确保这与UmiJS的默认构建行为兼容,或根据实际输出目录调整outputDirectory的值。

🤖 Prompt for AI Agents
In vercel.json around lines 1 to 3, the config only specifies "framework":
"umijs" and lacks explicit buildCommand and outputDirectory; add a buildCommand
(e.g. "npm run build") and an outputDirectory (e.g. "dist") to ensure Vercel
builds and serves the correct output, and if the project's package.json uses a
different build script (here "dumi build") or outputs to a different folder, set
buildCommand to that script and outputDirectory to the actual build output
directory accordingly.

@afc163 afc163 merged commit 4d8078c into master Nov 25, 2025
12 checks passed
@afc163 afc163 deleted the afc163-patch-1 branch November 25, 2025 03:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants